home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
IRIX Base Documentation 1998 November
/
IRIX 6.5.2 Base Documentation November 1998.img
/
usr
/
share
/
catman
/
u_man
/
cat1
/
rsh_bsd.z
/
rsh_bsd
Wrap
Text File
|
1998-10-20
|
4KB
|
133 lines
rrrrsssshhhh((((1111CCCC)))) rrrrsssshhhh((((1111CCCC))))
NNNNAAAAMMMMEEEE
rsh - remote shell
SSSSYYYYNNNNOOOOPPPPSSSSIIIISSSS
////uuuussssrrrr////bbbbssssdddd////rrrrsssshhhh host [ ----llll username ] [ ----nnnn ] command
////uuuussssrrrr////bbbbssssdddd////rrrrsssshhhh username@host [ ----nnnn ] command
DDDDEEEESSSSCCCCRRRRIIIIPPPPTTTTIIIIOOOONNNN
_r_s_h connects to the specified _h_o_s_t, and executes the specified _c_o_m_m_a_n_d.
_r_s_h copies its standard input to the remote command, the standard output
of the remote command to its standard output, and the standard error of
the remote command to its standard error. Interrupt, quit, and terminate
signals are propagated to the remote command; _r_s_h normally terminates
when the remote command does.
The remote username used is the same as your local username, unless you
specify a different remote name with the ----llll option or the _u_s_e_r_n_a_m_e@_h_o_s_t
format. This remote name must be equivalent (in the sense of _r_l_o_g_i_n(1C))
to the originating account; no provision is made for specifying a
password with a command.
If you omit _c_o_m_m_a_n_d, instead of executing a single command, you are
logged in on the remote host using _r_l_o_g_i_n(1C). In this case, _r_s_h
understands the additional arguments to _r_l_o_g_i_n.
Shell metacharacters that are not quoted are interpreted on local
machine, while quoted metacharacters are interpreted on the remote
machine. Thus the command
_rrrr_ssss_hhhh _oooo_tttt_hhhh_eeee_rrrr_hhhh_oooo_ssss_tttt _cccc_aaaa_tttt _rrrr_eeee_mmmm_oooo_tttt_eeee_ffff_iiii_llll_eeee _>>>>_>>>> _llll_oooo_cccc_aaaa_llll_ffff_iiii_llll_eeee
appends the remote file _r_e_m_o_t_e_f_i_l_e to the localfile _l_o_c_a_l_f_i_l_e, while
_rrrr_ssss_hhhh _oooo_tttt_hhhh_eeee_rrrr_hhhh_oooo_ssss_tttt _cccc_aaaa_tttt _rrrr_eeee_mmmm_oooo_tttt_eeee_ffff_iiii_llll_eeee _""""_>>>>_>>>>_"""" _oooo_tttt_hhhh_eeee_rrrr_rrrr_eeee_mmmm_oooo_tttt_eeee_ffff_iiii_llll_eeee
appends _r_e_m_o_t_e_f_i_l_e to _o_t_h_e_r_r_e_m_o_t_e_f_i_l_e.
SSSSEEEEEEEE AAAALLLLSSSSOOOO
rlogin(1C), hosts(4), rhosts(4).
BBBBUUUUGGGGSSSS
If you use _c_s_h(1), _r_s_h does not work if your ._c_s_h_r_c file on the remote
host unconditionally executes interactive or output-generating commands.
Put these commands inside the following conditional block:
if ($?prompt) then
endif
so they won't interfere with _r_c_p, _r_s_h, and other non-interactive,
_r_c_m_d(3N)-based programs.
PPPPaaaaggggeeee 1111
rrrrsssshhhh((((1111CCCC)))) rrrrsssshhhh((((1111CCCC))))
If you put a _r_s_h(1C) in the background without redirecting its input away
from the terminal, it blocks even if no reads are posted by the remote
command. If no input is desired, you should use the ----nnnn option, which
redirects the input of _r_s_h to /_d_e_v/_n_u_l_l.
You cannot run an interactive command (like _v_i(1)); use _r_l_o_g_i_n(1C).
Job control signals stop the local _r_s_h process only; this is arguably
wrong, but currently hard to fix.
PPPPaaaaggggeeee 2222